Prev | Next

Changing Flag Attributes

<< | >>

Understanding Stretch, Bend, And Shear

Overview

Each flag is created by a series of springs connected to the points in the flag mesh. The springs push and pull on each other, allowing wind and gravity to make the mesh look like cloth.

Three of the most important parameters that affect the flag's reaction to the environment are Flag Stretch, Flag Bend, and Flag Shear.

The reason these parameters are discussed together is because they are parameters that control the springs in the flag mesh.

Anatomy Of A Flag Mesh

Flags react to the environment because of calculations made to the springs that connect mesh points. There are three types of springs, and each type of spring can be controlled separately.

The diagram below shows how each spring is constructed.



Stretch Springs

These springs connect adjacent mesh points, horizontally and vertically.

Bend Springs

These springs connect every other mesh point, horizontally and vertically. Bend Springs overlap each other.

Shear Springs

These springs connect mesh points on the diagonal.

Stretch, Bend, And Shear Parameter Values

The Flag Stretch, Flag Bend, and Flag Shear values range from 0 to 100. They represent how much each spring can extend, as a percentage. The allowed extension is only a goal -- it is not guaranteed. As the springs push and pull against each other, some springs may end up out of range.

This constant pushing and pulling gives the flag its shape, causing undulation and ripples over the surface of the flag.

Small Values Are Highly Effective

You won't have to set the Flag Stretch, Flag Bend, and Flag Shear values very high for them to be effective. In fact, values over 20 (percent) may create flags that stretch too much to be useful.

Allowing The Flag To Stretch, Bend, and Shear

Let's see what happens when you change the Flag Stretch, Flag Bend, and Flag Shear values to allow the flag to expand up to 20% of its size.

  1. Open the "Quick Start.aep" project.
  2. Open the Options window by clicking the 3D Flag logo in the Effect Controls window.



  3. Pause the animation by pressing the spacebar.
  4. Find the Flag Stretch, Flag Bend, and Flag Shear parameters and set each to 20.



    You may have to wait while the flag is recalculated after each parameter change.

    Notice how the flag is now stretched out.



  5. Play the animation by clicking the Restart Simulation button. Notice that the flag is pushed and pulled more by the wind and gravity.
  6. When you're done watching the flag, click the OK button to close the Options window.

You may need to experiment a bit with the spring parameters to find values that fit your needs.

We can gain more control over the shape of the flag with the Conform parameter. The next section, Get The Wrinkles Out With Conform, will discuss this useful parameter.